package net.teamclerks.rpgf.avatar.controller;

import java.util.List;

import net.teamclerks.rpgf.avatar.Avatar;
import net.teamclerks.rpgf.script.director.Director;

/**
 * AvatarController is used to handle all the Avatars in a given
 * Scene (determined by the Director). AvatarController
 * moves characters around, keeps track of when an Avatar acts,
 * and relays that information to the Director.
 * @author msmith
 *
 */
public class AvatarController
{
  /// CONTROL DATA ///
  /**
   * The list of Avatars controlled by this AvatarController
   * for the Scene controlled by the Director.
   */
  protected List<Avatar> avatars;
  /**
   * Reference to the system's Director.
   */
  protected Director director;
  
  /// DENY CONSTRUCTOR ///
  private AvatarController(){}
  
  /// PUBLIC CONSTRUCTOR ///
  /**
   * Public Constructor
   * @param director
   */
  public AvatarController(Director director)
  {
    this();
    this.director = director;
    this.director.setAvatarController(this);
  }

  /// PUBLIC FINAL METHODS ///
  /**
   * @return the avatars
   */
  public final List<Avatar> getAvatars()
  {
    return avatars;
  }
  /**
   * @param avatars the avatars to set
   */
  public final void setAvatars(List<Avatar> avatars)
  {
    this.avatars = avatars;
  }
}
